
//Promise代表一个未来 某个将要发生的事件的对象
//参数executor 它会立刻同步执行
//
let promise = new Promise(function(resolve,reject){
    //resolve('value');
    reject('reason');
}); 
/* console.dir(Object.prototype.toString.call(promise))
console.log(promise.__proto__===Promise.prototype)
console.log(Object.getPrototypeOf(promise)===Promise.prototype) */
/**
[[Prototype]]: Promise
[[PromiseState]]: "pending"
[[PromiseResult]]: undefined
 */